package org.liquidByte.trafficMustang.androidApp.listview.row;

import java.security.InvalidParameterException;

import android.view.View;

public abstract class ListViewRow {
	private View view;

	protected ListViewRow(View view) {
		if (view == null) {
			throw new InvalidParameterException("view is null");
		}
		this.view = view;
	}
	
	protected View getView() {
		return this.view;
	}
	
	public abstract void init();
	
	protected <T extends View> T findViewById(Class<T> viewClass, int id) {
		return viewClass.cast(this.view.findViewById(id));
	}
}
